package com.lyb.mapper;

import com.lyb.pojo.RolePermission;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

@Mapper
public interface RolePermissionMapper {
    @Insert("insert into role_permission (roleId,permissionId) values (#{roleId},#{permissionId})")
    Boolean add(Long roleId, Long permissionId);
    @Select("select * from role_permission where roleId=#{id}")
    RolePermission findByRoleId(Long id);
}
